qui(
    function (require, exports, module) {
        Specimen.Action = (function () {
            var editForm = null;
            var listGrid = null;
            var hostGrid = null;
            var getListGrid = function (options) {
                if (!listGrid) {
                    listGrid = new Specimen.Grid($.extend(true, {
                        $grid:$("#list"),
                        $downloadGrid:$("#downloadList"),
                        type: 0
                    }, options));
                }
                return listGrid;
            }

            function  editRun () {
                if(editForm == null){
                    editForm = new Specimen.Edit($.extend(true, {
                    }, {}));
                    editForm.init();
                }
                console.log(' editRun ');
            }
            function listRun(options){
                listGrid = getListGrid(options);
                listGrid.runList();
                console.log('list grid run');
            }

            function hostFrameRun(){
                if(!hostGrid){
                    hostGrid = new Specimen.Grid($.extend(true, {
                        type: 0
                    }, {}));
                }
                hostGrid.hostRun();
            }

            return {
                listRun:listRun,
                editRun:editRun,
                hostFrameRun:hostFrameRun
            }
        })();
    }
);